import Mock from 'mockjs'

Mock.mock('/user/login', 'post', (req, res) => {
    return {
        code: 20000,
        data: {
            token: '123456-456789-789456'
        },
        msg: '成功'
    }
})

Mock.mock('/user/getMeInfo', 'get', (req, res) => {
    return {
        code: 20000,
        data: {
            roles: ['admin'],
            username: 123,
            avatar: "https://wpimg.wallstcn.com/f778738c-e4f8-4870-b634-56703b4acafe.gif?imageView2/1/w/80/h/80"
        },
        msg: '成功'
    }
})

Mock.mock('/user/logout', 'post', (req, res) => {
    return {
        code: 20000,
        data: null,
        msg: '成功'
    }
})
